package com.baizhi.controller;


import com.baizhi.entity.SpuInfo;
import com.baizhi.service.ISpuInfoService;
import com.baizhi.vo.R;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;

import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * <p>
 * spu信息 前端控制器
 * </p>
 *
 * @author huiJie
 * @since 2021-08-31
 */
@RestController
@RequestMapping("/spuInfo")
public class SpuInfoController {
    @Autowired
    private ISpuInfoService spuInfoService;
    @GetMapping
    public R showSpu(){
        List<SpuInfo> list = spuInfoService.list();
        return R.ok(list);
    }
}

